home *** CD-ROM | disk | FTP | other *** search
/ QRZ! Ham Radio 8 / QRZ Ham Radio Callsign Database - Volume 8.iso / pc / files / t_sys5 / unixkit.tgz / unixkit.tar / unixkit / tundrvr / tund / Makefile < prev    next >
Makefile  |  1989-05-07  |  2KB  |  99 lines

  1. #################################################################
  2. #
  3. # Makefile for tunnel stuff
  4. #
  5. #
  6. #
  7. # Copyright (c) 1988, Julian Onions. 
  8. #
  9. # This source may be freely distributed, however I would be interested
  10. # in any changes that are made.
  11. #
  12. # Changes for SunOS4.0, eckert@uni-erlangen.de
  13. #
  14. # $Header: Makefile,v 1.4 88/07/11 08:28:32 jpo Exp $
  15. #
  16. # $Log:    Makefile,v $
  17. # Revision 1.4  88/07/11  08:28:32  jpo
  18. # Some tidying up
  19. # Revision 1.3  88/01/25  13:59:42  jpo
  20. # New bits
  21. # Revision 1.2  87/11/04  15:13:32  jpo
  22. # Example and a few missing bits.
  23. # Revision 1.1  87/11/04  10:30:49  jpo
  24. # Initial revision
  25. #
  26. #################################################################
  27. #
  28. # Definitions
  29. #
  30. #################################################################
  31.  
  32. # for SunOs 4.0
  33. CFLAGS    = -g -DSUNOS4
  34. # for SunOs 3.x
  35. #CFLAGS    = -g
  36. CC    = gcc -traditional
  37. LDFLAGS    = -g # -Bstatic
  38. LINT    = lint
  39. LLFLAGS    = -haxbc
  40. DIST    = README Makefile tund.c lcd.c tundebug.c tund.8c config.example \
  41.     tund.h tun.4n MAKEDEV.tun if_tun.c if_tnreg.h 
  42. OWNER    = root
  43. GRP    = wheel
  44. DESTDIR    = /usr/local
  45.  
  46. #################################################################
  47. #
  48. # Rules ...
  49. #
  50. #################################################################
  51.  
  52. all: if_tnreg.h tund tundebug tun.4n tund.8c MAKEDEV.tun
  53.  
  54. tund: tund.o lcd.o
  55.     $(CC) $(LDFLAGS) -o $@ tund.o lcd.o
  56.  
  57. tund.o lcd.o: tund.h
  58.  
  59. lint: l-tund l-tundebug
  60.  
  61. l-tund: tund.c lcd.c
  62.     $(LINT) $(LLFLAGS) tund.c lcd.c
  63.  
  64. l-tundebug: tundebug.c
  65.     $(LINT) $(LLFLAGS) tundebug.c
  66.  
  67. tundebug: tundebug.c
  68.     $(CC) $(LDFLAGS) -o $@ tundebug.c
  69.  
  70. install: if_tnreg.h tund tundebug tun.4n tund.8c MAKEDEV.tun
  71.     install -m 644 -o $(OWNER) -g $(GRP) if_tnreg.h $(DESTDIR)/include/netinet
  72.     rm -f /usr/include/netinet/if_tnreg.h
  73.     ln -s $(DESTDIR)/include/netinet/if_tnreg.h /usr/include/netinet/if_tnreg.h
  74.     install -m 755 -o $(OWNER) -g $(GRP) tund tundebug $(DESTDIR)/etc
  75.     install -m 644 -o $(OWNER) -g $(GRP) tun.4n  $(DESTDIR)/man/man4
  76.     install -m 644 -o $(OWNER) -g $(GRP) tund.8c  $(DESTDIR)/man/man8
  77.     install -m 755 -o $(OWNER) -g $(GRP) MAKEDEV.tun /etc
  78.  
  79.  
  80. clean: tidy
  81. tidy:
  82.     rm -f *.o core a.out tunnel.shar
  83.  
  84. clobber: tidy
  85.     rm -f tund tundebug tags TAGS
  86.     sccs clean
  87.  
  88. shar: tunnel.shar
  89. tunnel.shar: $(DIST)
  90.     shar -cv $(DIST) > $@
  91.  
  92. tar: $(DIST)
  93.     tar cvf tunnel.tar $(DIST)
  94.     compress tunnel.tar
  95.